home *** CD-ROM | disk | FTP | other *** search
/ Aminet 15 / Aminet 15 - Nov 1996.iso / Aminet / dev / basic / ace24dist.lha / ace24.lha / include / rexx / rexxio.h < prev    next >
C/C++ Source or Header  |  1996-09-10  |  3KB  |  98 lines

  1. #ifndef REXX_REXXIO_H
  2. #define REXX_REXXIO_H 1
  3. /*
  4. ** rexxio.h for ACE Basic
  5. **
  6. ** Note: Translated to ACE by ConvertC2ACE
  7. **       @ MapMeadow Software, Nils Sjoholm
  8. **
  9. **
  10. ** Date: 09/03/95
  11. **
  12. **
  13. */
  14.  
  15. /*
  16. ** This are the StructPointer defines for rexxio.h
  17. */
  18. #ifndef IoBuffPtr
  19. #define IoBuffPtr ADDRESS
  20. #endif
  21. #ifndef RexxMsgPortPtr
  22. #define RexxMsgPortPtr ADDRESS
  23. #endif
  24. /*
  25. ** End of StructPointer defines for rexxio.h
  26. */
  27.  
  28.  
  29. #ifndef REXX_STORAGE_H
  30. #include <rexx/storage.h>
  31. #endif
  32.  
  33. #define RXBUFFSZ  204              /* buffer length     */
  34.  
  35. /*
  36.  * The IoBuff is a resource node used to maintain the File List.  Nodes
  37.  * are allocated and linked into the list whenever a file is opened.
  38.  */
  39. STRUCT IoBuff  
  40.    RexxRsrc iobNode         /* structure for files/strings   */
  41.    ADDRESS     iobRpt             /* read/write pointer        */
  42.    LONGINT     iobRct             /* character count       */
  43.    LONGINT     iobDFH             /* DOS filehandle        */
  44.    ADDRESS     iobLock                /* DOS lock          */
  45.    LONGINT     iobBct             /* buffer length     */
  46.    STRING iobArea SIZE 204  /* RXBUFFSZ  */         /* buffer AREA           */
  47. END STRUCT                       /* SIZE: 256 bytes       */
  48.  
  49. /* Access mode definitions                      */
  50. #define RXIO_EXIST   -1        /* an external filehandle    */
  51. #define RXIO_STRF    0             /* a "string file"       */
  52. #define RXIO_READ    1             /* read-only access      */
  53. #define RXIO_WRITE   2             /* write mode            */
  54. #define RXIO_APPEND  3             /* append mode (existing file)   */
  55.  
  56. /*
  57.  * Offset anchors for SeekF()
  58.  */
  59. #define RXIO_BEGIN   -1&           /* relative TO start     */
  60. #define RXIO_CURR    0&        /* relative TO current position  */
  61. #define RXIO_END     1&        /* relative TO END       */
  62.  
  63. /* The Library List contains just plain resource nodes.     */
  64.  
  65. #define LLOFFSET(rrp) (rrp->rr_Arg1)   /* "Query" offset        */
  66. #define LLVERS(rrp)   (rrp->rr_Arg2)   /* library version       */
  67.  
  68. /*
  69.  * The RexxClipNode structure is used to maintain the Clip List.  The value
  70.  * string is stored as an argstring in the rr_Arg1 field.
  71.  */
  72. #define CLVALUE(rrp) ((ADDRESS) rrp->rr_Arg1)
  73.  
  74. /*
  75.  * A message port structure,  maintained as a resource node.  The ReplyList
  76.  * holds packets that have been received but haven't been replied.
  77.  */
  78. STRUCT RexxMsgPort  
  79.    RexxRsrc rmp_Node            /* linkage node          */
  80.    MsgPort rmp_Port            /* the message port      */
  81.    _List rmp_ReplyList       /* messages awaiting reply   */
  82.    END STRUCT 
  83.  
  84. /*
  85.  * DOS Device types
  86.  */
  87. #define DT_DEV    0&               /* a device          */
  88. #define DT_DIR    1&               /* an ASSIGNed directory */
  89. #define DT_VOL    2&               /* a volume          */
  90.  
  91. /*
  92.  * Private DOS packet types
  93.  */
  94. #define ACTION_STACK 2002&         /* stack a LINE          */
  95. #define ACTION_QUEUE 2003&         /* queue a LINE          */
  96.  
  97. #endif
  98.